// This is an open source non-commercial project. Dear PVS-Studio, please check it.
// PVS-Studio Static Code Analyzer for C, C++ and C#: http://www.viva64.com

// ReSharper disable CheckNamespace
// ReSharper disable CommentTypo
// ReSharper disable IdentifierTypo
// ReSharper disable InconsistentNaming
// ReSharper disable LocalizableElement
// ReSharper disable StringLiteralTypo
// ReSharper disable UnusedMember.Global
// ReSharper disable UseNameofExpression

/*
 * Ars Magna project, http://arsmagna.ru
 */

namespace AM.HtmlTags;

public class FormTag : HtmlTag
{
    public FormTag (string url) : this()
    {
        Action (url);
    }

    public FormTag() : base ("form")
    {
        Method ("post");
    }

    public FormTag Method (string httpMethod)
    {
        Attr ("method", httpMethod);
        return this;
    }

    public FormTag Action (string url)
    {
        Attr ("action", url);
        return this;
    }
}
